package com.huashi.dealer.modular.controller.store.dashboard.param;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.math.BigDecimal;
import java.util.List;

@Data
@Schema(description = "门店后台首页聚合返回")
public class StoreDashboardResponse {

    @Schema(description = "最新订单块")
    private OrderBlock order;

    @Schema(description = "概要统计块")
    private WidgetOutline widgetOutline;

    @Schema(description = "待办统计块")
    private WidgetEcharts widgetEcharts;

    @Data
    @Schema(description = "最新订单块")
    public static class OrderBlock {
        @Schema(description = "最新订单号列表")
        private List<OrderNoItem> messageOrderNo;
    }

    @Data
    @Schema(description = "订单号项")
    public static class OrderNoItem {
        private Long orderId;
        private String orderNo;
    }

    @Data
    @Schema(description = "概要统计")
    public static class WidgetOutline {
        @Schema(description = "年度目标(字符串，带千分位)")
        private String salesMoney;
        @Schema(description = "拿货金额")
        private BigDecimal all;
        @Schema(description = "完成进度，百分比字符串")
        private String percentage;
        @Schema(description = "基本账户充值金额合计")
        private BigDecimal balanceAll;
    }

    @Data
    @Schema(description = "待办统计")
    public static class WidgetEcharts {
        @Schema(description = "打款单待审核数")
        private Integer applyNumber;
        @Schema(description = "待审核订单总量")
        private Integer orderTotal;
        @Schema(description = "待发货订单总量")
        private Integer deliveryOrderTotal;
    }
}


